from iniconfig import IniConfig

def read_ini():
    ini = IniConfig('6_requests/project/bysms/pytest.ini')
    print(type(ini))  #<class 'iniconfig.IniConfig'>
    print(ini['base_url'])
    print(type(ini['base_url']))  #<class 'iniconfig.SectionWrapper'>
    a = ini['base_url'].items()
    print(type(a))  #<class 'generator'>
    print(dict(a))


read_ini()